<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:f="http://java.sun.com/jsf/core"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:p="http://primefaces.prime.com.tr/ui">

    <body>

        <ui:composition template="./../../Template/generalTemplate.xhtml">


            <ui:define name="content">
                <h:form id="form" prependId="false">
                    <p:panel id="AuditTrail" header="View Audit Trial Records" style="height:495px;">

                        <div style="margin-top:20px;margin-left:30px;margin-right:30px;margin-bottom:20px;"> 
                            <p:dataTable id="auiditTrail" dynamic="true" emptyMessage="No Record Exists" value="#{viewAuditTrailManagedBean.getAllAuditTrails()}" var ="o" paginator="true" rows="6">

                                <p:column filterBy="#{o.date}" filterMatchMode="contains" headerText="Date">
                                    #{o.date}
                                </p:column>

                                <p:column filterBy="#{o.userName}" filterMatchMode="contains" headerText="User Name">
                                    #{o.userName}
                                </p:column>

                                <p:column filterBy="#{o.module}" filterMatchMode="contains" headerText="Module">
                                    #{o.module}
                                </p:column> 

                                <p:column filterBy="#{o.process}" filterMatchMode="contains" headerText="Process">
                                    #{o.process}
                                </p:column> 
                                
                                <p:column filterBy="#{o.recordId}" filterMatchMode="contains" headerText="Record Id">
                                    #{o.recordId}
                                </p:column> 

                                <p:column filterBy="#{o.action}" filterMatchMode="contains" headerText="Action">
                                    #{o.action}
                                </p:column> 

                                <p:column filterBy="#{o.notes}" filterMatchMode="contains" headerText="Notes">
                                    #{o.notes}
                                </p:column> 

                            </p:dataTable>


                        </div>


                    </p:panel>
                </h:form>
            </ui:define>


        </ui:composition>

    </body>
</html>
